package com.ccit.service;


import com.ccit.domain.Employee;
import com.ccit.domain.PageBean;
import org.apache.ibatis.annotations.Param;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Transactional
public interface EmployeeService {


    public boolean add(Employee employee);

    /**
     * 按id查询
     * @param id
     * @return
     */
    public Employee getById(Integer id);


    /**
     * 按id删除
     * @param id
     * @return
     */
    public boolean delete(Integer id);

    /**
     * 修改
     *
     * @param employee
     * @return
     */
    public boolean update(Employee employee);

    /**
     * 查询全部
     * @return
     */
    public List<Employee> selectAll();


    /**
     * 分页查询
     * @param currentPage  当前页码
     * @param pageSize   每页展示条数
     * @return
     */
    PageBean<Employee> selectByPage(int currentPage, int pageSize);

    /**
     * 批量删除
     * @param ids
     */
    public boolean deleteByIds(@Param("ids") Integer[] ids);





}
